import request from '@/utils/request'

// 查询用户问答历史列表
export function listDialoghistory(query) {
  return request({
    url: '/dialoghistory/dialoghistory/list',
    method: 'get',
    params: query
  })
}

// 查询用户问答历史详细
export function getDialoghistory(id) {
  return request({
    url: '/dialoghistory/dialoghistory/' + id,
    method: 'get'
  })
}

// 新增用户问答历史
export function addDialoghistory(data) {
  return request({
    url: '/dialoghistory/dialoghistory',
    method: 'post',
    data: data
  })
}

// 修改用户问答历史
export function updateDialoghistory(data) {
  return request({
    url: '/dialoghistory/dialoghistory',
    method: 'put',
    data: data
  })
}

// 删除用户问答历史
export function delDialoghistory(id) {
  return request({
    url: '/dialoghistory/dialoghistory/' + id,
    method: 'delete'
  })
}

// 获取词频数据
export function getWordCloudData() {
  return request({
    url: '/dialoghistory/dialoghistory/wordCloud',
    method: 'get'
  })
}
